Interactive maps

Load data

Define color palettes

#define some color palettes that flip at 1
pal_rdylgn5=RColorBrewer::brewer.pal(n=5,"RdYlGn")
pal_rdylgn5_rev=rev(pal_rdylgn5)

pal_rdylbu=RColorBrewer::brewer.pal(n=5,"RdYlBu")
pal_rdylbu_rev=rev(pal_rdylbu)

viridis_5=viridis(5)

Baseline maps: hospitalizations and covariates

Baseline hospitalizations

Maren, in the data you shared, I wasn’t sure which var corresponded to the baseline number of hospitalizations. I mapped population here as a stand-in.

tmap_mode("view") #run again just in case it was changed above.
qtm_pop= zcta_ca_geo_simplified %>% 
  left_join(covars, by = "zcta") %>% 
  #remove everything without a geometry
  filter(is.na(Pop)==F) %>% 
  qtm("Pop")
qtm_pop

Tree canopy

Impervious surface

SVI

IRR

Impervious surfaces

Population-based

Proportionate Universalism 1

Proportionate Universalism 2

Proportionate Universalism 3

Tree canopy

IRD

Impervious surfaces

Population-based